﻿<%@ Page Title="" Language="C#" MasterPageFile="~/admin/admin.master" AutoEventWireup="true" CodeFile="Default.aspx.cs" Inherits="admin_artcles_class_Default" %>

<asp:Content ID="Content1" ContentPlaceHolderID="head" Runat="Server">
    <link href="StyleSheet.css" rel="Stylesheet" />
    <asp:Literal ID="scriptmsg" runat="server"></asp:Literal>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" Runat="Server">
    <h1>文章分类管理</h1>
    <br />
    <asp:GridView ID="ClassListBox" runat="server" AutoGenerateColumns="False" 
        EnableModelValidation="True" Width="720px" CellPadding="4" 
        ForeColor="#333333" GridLines="None" 
        onselectedindexchanged="ClassListBox_SelectedIndexChanged" >
        <AlternatingRowStyle BackColor="White" />
        <Columns>
            <asp:CommandField ShowSelectButton="True" ItemStyle-Width="40px" >
<ItemStyle Width="40px"></ItemStyle>
            </asp:CommandField>
            <asp:BoundField DataField="CID" HeaderText="分类ID" ItemStyle-Width="40px" />
            <asp:BoundField DataField="CName" HeaderText="分类名称" />
            <asp:BoundField DataField="COrder" HeaderText="排序" ItemStyle-Width="40px" />
            <asp:BoundField DataField="CRemarks" ItemStyle-Width="0px" />
        </Columns>
        
        <EditRowStyle BackColor="#2461BF" />
        <FooterStyle BackColor="#507CD1" Font-Bold="True" ForeColor="White" />
        <HeaderStyle BackColor="#507CD1" Font-Bold="True" ForeColor="White" />
        <PagerStyle BackColor="#2461BF" ForeColor="White" HorizontalAlign="Center" />
        <RowStyle BackColor="#EFF3FB" />
        <SelectedRowStyle BackColor="#D1DDF1" Font-Bold="True" ForeColor="#333333" />
        
    </asp:GridView>
    <br />

    <div id="editbox">
    <div id="editleft">
        <p>分类名称：<asp:TextBox ID="NameBox" runat="server" Height="16px" 
                Width="225px" CssClass="cinput"></asp:TextBox></p>
        <p>分类描述：<br />
            <asp:TextBox ID="RemarkBox" runat="server" BorderStyle="Solid" 
                Height="71px" TextMode="MultiLine" Width="329px" CssClass="cinput"></asp:TextBox></p>
        <p>分类顺序：<asp:TextBox ID="OrderBox" runat="server" BorderStyle="Solid" Width="30px" 
                Text="0" CssClass="cinput"></asp:TextBox><asp:RegularExpressionValidator
            ID="RegularExpressionValidator1" runat="server" ErrorMessage="错误！只能输入数字！" 
            ControlToValidate="OrderBox" ValidationExpression="\d+"></asp:RegularExpressionValidator></p>
    </div>
    <div id="editright">
        <asp:Button ID="Button1" runat="server" Text="修改" CssClass="bluebutton" 
            onclick="Button1_Click" /><br /><br />
        <asp:Button ID="Button2"
            runat="server" Text="添加" CssClass="bluebutton" onclick="Button2_Click" /><br /><br />
        <asp:Button ID="Button3" runat="server" Text="删除" CssClass="bluebutton" 
            onclick="Button3_Click" OnClientClick="return confirm('是否确定删除') " />
            <input type="hidden" id="hID" name="suredel" />
    </div>
    </div>
</asp:Content>

